﻿using System;
using SharpSqlAnalyzer.nodes;

namespace SharpSqlAnalyzer.stmt
{
	// Token: 0x020000A4 RID: 164
	public class TDropSchemaSqlStatement : TCustomSqlStatement
	{
		// Token: 0x0600051D RID: 1309 RVA: 0x002FC975 File Offset: 0x002FAB75
		public TDropSchemaSqlStatement(EDbVendor dbvendor) : base(dbvendor)
		{
			this.sqlstatementtype = ESqlStatementType.sstdropschema;
		}

		// Token: 0x170000CC RID: 204
		// (get) Token: 0x0600051E RID: 1310 RVA: 0x002FC986 File Offset: 0x002FAB86
		// (set) Token: 0x0600051F RID: 1311 RVA: 0x002FC98E File Offset: 0x002FAB8E
		public virtual TObjectName SchemaName
		{
			get
			{
				return this.schemaName;
			}
			set
			{
				this.schemaName = value;
			}
		}

		// Token: 0x170000CD RID: 205
		// (get) Token: 0x06000520 RID: 1312 RVA: 0x002FC997 File Offset: 0x002FAB97
		public virtual TSourceToken DropBehavior
		{
			get
			{
				return this.dropBehavior;
			}
		}

		// Token: 0x06000521 RID: 1313 RVA: 0x002FC9A0 File Offset: 0x002FABA0
		public override int doParseStatement(TCustomSqlStatement psql)
		{
			if (this.rootNode == null)
			{
				return -1;
			}
			base.doParseStatement(psql);
			this.schemaName = (TObjectName)((TDummy)this.rootNode).node1;
			this.schemaName.DbObjectType = EDbObjectType.schema;
			base.DatabaseObjects.Add(this.schemaName);
			this.dropBehavior = ((TDummy)this.rootNode).st1;
			return 0;
		}

		// Token: 0x06000522 RID: 1314 RVA: 0x002FCA0F File Offset: 0x002FAC0F
		public override void accept(TParseTreeVisitor v)
		{
			v.preVisit(this);
			v.postVisit(this);
		}

		// Token: 0x06000523 RID: 1315 RVA: 0x002FCA1F File Offset: 0x002FAC1F
		public override void acceptChildren(TParseTreeVisitor v)
		{
			v.preVisit(this);
			v.postVisit(this);
		}

		// Token: 0x04001133 RID: 4403
		private TObjectName schemaName;

		// Token: 0x04001134 RID: 4404
		private TSourceToken dropBehavior;
	}
}
